#include "day8.h"
#include <QApplication>
#include <osg/FrameBufferObject>
#include <osg/Texture>
#include <osg/TextureCubeMap>
#include <osg/GraphicsContext>
#include <CommonLib/MainWindow/MainWindow.h>
#include <CommonLib/ListWidget/ListWidget.h>
#include <CommonLib/HudRtt/EventInteract.h>

int day8( int argc, char **argv )
{
    QApplication app(argc, argv);
    CMainWindow mainWindow;
    CListWidget listWidget(&mainWindow);

    CHUDProvider HudProvider;
    listWidget.addModel(QString::fromLocal8Bit("cow"), HudProvider.createHUD());
    listWidget.addModel("cow.osg");
    auto pGroup = HudProvider.CreateRTTScale(mainWindow.getViewer() );
    listWidget.addModel(QString::fromLocal8Bit("rtt"), pGroup);

    mainWindow.home();
    mainWindow.setGeometry( 560, 240, 800, 600 );
    mainWindow.show();

    return app.exec();
}
